package com.qyhl.school.school.reporter.publish;


import com.qyhl.webtv.commonlib.entity.UpTokenBean;

public class SchoolReportPublishPresenter implements SchoolReportPublishContract.SchoolReportPublishPresenter {
    private SchoolReportPublishContract.SchoolReportPublishView mView;
    private SchoolReportPublishModel mModel;

    public SchoolReportPublishPresenter(SchoolReportPublishContract.SchoolReportPublishView mView) {
        this.mView = mView;
        this.mModel = new SchoolReportPublishModel(this);
    }


    @Override
    public void doPost(String username, String content, String title, String school, String writer, String image) {
        mModel.doPost(username, content, title, school, writer, image);
    }

    @Override
    public void getToken(boolean isUpload) {
        mModel.getToken(isUpload);
    }

    @Override
    public void postResult(boolean isSuccess, String msg) {
        mView.postResult(isSuccess, msg);
    }

    @Override
    public void getTokenSuccess(UpTokenBean data, boolean isUpload) {
        mView.getTokenSuccess(data, isUpload);
    }

    @Override
    public void getTokenError(boolean isUpload) {
        mView.getTokenError(isUpload);
    }
}
